{% extends "TextBadger/base.html" %}

{% block css %}
        <link rel="stylesheet" href="/static/TextBadger/css/account.css">
{% endblock %}

{% block onDocLoad %}
        $('.menuitem').removeClass('menuitemselected');
        $("#mnuaccount").addClass("menuitemselected");
{% endblock %}

{% block maincontent %}
	<div id="PageHeading">Basic Info</div>
        <div id='accountform'>
        	<form action='' method="post">
                	{% for field in accountform %}
                	<div class='formfieldcontainer'>
	                      	<label class='fieldlabel' for='id_{{ field.name }}'>{{ field.label }} :</label>
                                {{ field }}
                                {% for error in field.errors %}
	                                <label class='fielderror'>{{ error }}</label>
                                {% endfor %}
			</div>
                        {% endfor %}

                        <input type = "submit" class="button-base button-medium button-blue" value="Update" />
			{% if saved %}
				<span style='margin-left:10px;' class="positiveresponse ui-corner-all">
                			Information Saved
				</span>
			{% endif %}
		</form>
	</div>

	<form action='/deleteaccount/' method='POST'>
		<input type='submit' style='margin-left:10px;' class="button-base button-medium button-blue" value='Delete Account' onclick='return confirm("Are you sure you want to delete your account?")' />
	</form>
{% endblock %}

